package com.molichuxing.services.infrastructure.service;

import com.molichuxing.framework.dto.Paged;
import com.molichuxing.framework.service.RootService;
import com.molichuxing.services.infrastructure.dto.request.create.PaymentEnterpriseCreateDto;
import com.molichuxing.services.infrastructure.dto.response.PaymentEnterpriseDto;

import java.util.List;
import java.util.Map;

/**
 * <p>
 * 企业订单支付
 * </p>
 *
 * @author zhaopenghui
 * @since 2020-06-05
 */
public interface PaymentEnterpriseService extends RootService {

    /**
     * 分页企业支付
     *
     * @param params   orderCode：订单类型
     *                 enterpriseId:企业id
     * @param pageNum  页数
     * @param pageSize 每页条数
     * @return
     * @throws Exception
     */
    Paged<PaymentEnterpriseDto> getEnterprisePage(Map<String, Object> params, int pageNum, int pageSize)
            throws Exception;

    /**
     * 获取支付记录数
     *
     * @return
     */
    Integer getEnterpriseCount();

    /**
     * 根据id查询支付信息
     *
     * @param id
     * @return
     */
    PaymentEnterpriseDto getById(Integer id);

    /**
     * 根据id查询支付信息
     *
     * @param scheduleId
     * @return
     */
    PaymentEnterpriseDto getByScheduleId(Integer scheduleId);

    /**
     * 新增企业订单支付信息
     *
     * @param createDto 新增信息
     * @return boolean
     */
    boolean create(PaymentEnterpriseCreateDto createDto);

    /**
     * 查询企业订单支付信息
     *
     * @param scheduleIds 排期ids
     * @return
     */
    Map<Integer, PaymentEnterpriseDto> getEnterprise(List<Integer> scheduleIds);
}
